$('#addSku').click(function () {
    var jd = '<div class="layui-form-item">\n' +
        '                <label class="layui-form-label">名称</label>\n' +
        '                <div class="layui-input-inline">\n' +
        '                    <input type="text" name="sku_name" autocomplete="off" placeholder="规格名称" class="layui-input">\n' +
        '                </div>\n' +
        '                <div class="layui-input-inline">\n' +
        '                    <input type="text" name="sku_price" autocomplete="off" placeholder="价格" class="layui-input">\n' +
        '                </div>\n' +
        '            </div>';
    $('.sku_div').append(jd);
});

$('#addColor').click(function () {
    var jd = ' <div class="layui-form-item">\n' +
        '                <label class="layui-form-label">颜色</label>\n' +
        '                <div class="layui-input-inline">\n' +
        '                    <input type="text" name="color_name" autocomplete="off" placeholder="规格名称" class="layui-input">\n' +
        '                </div>\n' +
        '                <div class="layui-input-block">\n' +
        '                    <div class="layui-upload">\n' +
        '                        <button type="button" class="layui-btn layui-btn-normal" id="test8">选择文件</button>\n' +
        '                        <button type="button" class="layui-btn" id="test9">开始上传</button>\n' +
        '                    </div>\n' +
        '                </div>\n' +
        '            </div>';
    $('.color_div').append(jd);
});